import { requestClient } from '#/api/request';

export function GetList(query: any) {
  return requestClient.request('/gateway/rules/routes', {
    method: 'get',
    params: query,
  });
}

export function SaveOrUpdate(obj) {
  return requestClient.request('/gateway/rules/routes', {
    method: 'post',
    data: obj,
  });
}
export function DelObj(id: any) {
  return requestClient.request(`/gateway/rules/routes/${id}`, {
    method: 'delete',
    data: { id },
  });
}

export function ServiceStatus(id, status) {
  return requestClient.request(`/gateway/rules/routes/${id}/${status}`, {
    method: 'patch',
  });
}
